<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html lang="ko">
<head>
<title>하나의 인스턴스로 사용하는 예제</title>
<meta name="class-lists" content="jindo.LayerPosition"/>
<meta name="screenshots" content=""/>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Content-Script-Type" content="text/javascript">
<meta http-equiv="Content-Style-Type" content="text/css">
<meta name="description" content="하나의 인스턴스로 3개의 레이어를 배치하는 예제입니다.">
<link rel="stylesheet" type="text/css" href="../asset/demo.css">
<style type="text/css">
	.center_layer {position:absolute; top:150px; left:200px; width:150px; height:150px; padding:5px;  background-color:#666; color:white; border:1px solid black; text-align:center;}
	.layer {position:absolute; width:80px; height:80px; padding:5px; background-color:white; border:1px solid black; z-index:2; }
</style>
</head>
<body>
<script type="text/javascript" src="../asset/demojs/demo.js#header"
     data-title="Jindo Component"
     data-subtitle="=document.title"
     data-backbutton="false"
     data-viewsource="false"
     data-qrcode="true"></script>
	
<div id="center" class="center_layer">center layer</div>
<div id="layer1" class="layer">center layer 외부 좌상단</div>

<div id="layer2" class="layer">center layer 외부 상단 가운데 정렬</div>
<div id="layer3" class="layer">document body 내부 우상단</div>

<script type="text/javascript" charset="utf-8" src="../../asset/jindo.desktop.all.ns.js"></script>
<script type="text/javascript" charset="utf-8" src="../../source/jindo.Component.js"></script>
<script type="text/javascript" charset="utf-8" src="../../source/jindo.LayerPosition.js"></script>
<script type="text/javascript">
	var oLayerPosition = new jindo.LayerPosition();
	oLayerPosition.setElement(jindo.$("center")).setLayer(jindo.$("layer1")).option( { sPosition : "outside-top-left", nTop : 10, nLeft : 10 }).setPosition();
	oLayerPosition.setElement(jindo.$("center")).setLayer(jindo.$("layer2")).option( { sPosition : "outside-top", sAlign : "center", nTop : 10, nLeft : 10 }).setPosition();
	oLayerPosition.setElement(document.body).setLayer(jindo.$("layer3")).option( { sPosition : "inside-top-right", nTop : 10, nLeft : 10 }).setPosition();
</script>
<script type="text/javascript" src="../asset/demojs/demo.js#footer"></script>
</body>
</html>